<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
<title>手工护理消费结算</title>
<meta name="decorator" content="default" />
<style type="text/css">
</style>
<script type="text/javascript">
	$().ready(function() {
		disableExitMenu();
	});
</script>
</head>
<body>
	<div data-role="navbar">
		<ul>
			<c:if test="${member.menuState.hasNewCards}">
				<li><a href="${ctx}/cash/member/shoppingDetails">新开卡消费结算</a></li>
			</c:if>
			<c:if test="${member.menuState.hasRecharges}">
				<li><a href="${ctx}/cash/member/shoppingDetails/recharge">卡充值消费结算</a></li>
			</c:if>
			<c:if test="${member.menuState.hasProducts}">
				<li><a href="${ctx}/cash/member/shoppingDetails/product">购买产品消费结算</a></li>
			</c:if>
			<c:if test="${member.menuState.hasCares}">
				<li><a class="ui-btn-active" href="#">手工护理消费结算</a></li>
			</c:if>
			<c:if test="${member.menuState.hasGifts}">
				<li><a href="${ctx}/cash/member/shoppingDetails/gift">赠品</a></li>
			</c:if>
		</ul>
	</div>
	<div class="container">
		<h2 style="text-align: center;">确认结算方式</h2>
		<div class="icon-buttons">
			<a href="${ctx}/cash/member/detail?id=${member.customer.id}"
				data-inline="true" data-icon="back" data-iconpos="notext"
				data-role="button">返回</a> <a data-role="button" data-inline="true"
				data-icon="check" data-iconpos="notext"
				href="${ctx}/cash/member/shoppingPayment?id=${member.customer.id}">结算</a>
		</div>
		<tags:message content="${message}" />

		<div>
			<div data-role="fieldcontain">
				<label><strong>总计手工护理费用(元)：</strong></label> <input id="totalMonney"
					type="text" readonly
					value="${member.payment.caresPayment.totalPay}" />
			</div>
			<div data-role="collapsible-set">
				<c:if
					test="${not empty member.shoppingCart.systemCares or not empty member.shoppingCart.storeCares}">
					<div id="collapsibleForNewCard" data-role="collapsible"
						data-collapsed="false">
						<h4>自选产品(${fn:length(member.shoppingCart.systemCares)+fn:length(member.shoppingCart.storeCares)})</h4>
						<table id="contentTableCardTimes" data-role="table"
							class="ui-responsive table-stroke">
							<thead>
								<tr>
									<th colspan="6" style="text-align:center;">选购护理项目结算</th>
								</tr>
								<tr>
									<th>护理项目</th>
									<th>护理次数</th>
									<th>零售单价</th>
									<th>结算单价</th>
									<th>合计</th>
									<th>确认付款方式</th>
								</tr>
							</thead>
							<tbody>
								<c:forEach items="${member.shoppingCart.systemCares}"
									var="careCart">
									<tr>
										<td>${careCart.careDescription.name}</td>
										<td>${careCart.count}</td>
										<td>${careCart.careDescription.price}</td>
										<td>${careCart.realCost}</td>
										<td>${careCart.realCostTotal}</td>
										<td>${careCart.payment.description}</td>
									</tr>
								</c:forEach>
								<c:forEach items="${member.shoppingCart.storeCares}"
									var="careCart">
									<tr>
										<td>${careCart.careDescription.name}</td>
										<td>${careCart.count}</td>
										<td>${careCart.careDescription.price}</td>
										<td>${careCart.realCost}</td>
										<td>${careCart.realCostTotal}</td>
										<td>${careCart.payment.description}</td>
									</tr>
								</c:forEach>
							</tbody>
						</table>
					</div>
				</c:if>
				<c:if test="${not empty member.shoppingCart.solutionCares}">
					<div id="collapsibleForNewCard" data-role="collapsible"
						data-collapsed="false">
						<h4>方案产品(${fn:length(member.shoppingCart.solutionCares)})</h4>
						<table id="contentTableCardTimes" data-role="table"
							class="ui-responsive table-stroke">
							<thead>
								<tr>
									<th colspan="6" style="text-align:center;">选购护理项目结算</th>
								</tr>
								<tr>
									<th>护理项目</th>
									<th>护理次数</th>
									<th>零售单价</th>
									<th>结算单价</th>
									<th>合计</th>
									<th>确认付款方式</th>
								</tr>
							</thead>
							<tbody>
								<c:forEach items="${member.shoppingCart.solutionCares}"
									var="careCart">
									<tr>
										<td>${careCart.careDescription.name}</td>
										<td>${careCart.count}</td>
										<td>${careCart.careDescription.price}</td>
										<td>${careCart.realCost}</td>
										<td>${careCart.realCostTotal}</td>
										<td>${careCart.payment.description}</td>
									</tr>
								</c:forEach>
							</tbody>
						</table>
					</div>
				</c:if>
			</div>
		</div>
	</div>
	</div>
</body>
</html>
